package com.wx.service;

import org.springframework.transaction.annotation.Transactional;

import com.wx.entity.WechatUser;
import com.wx.entity.WechatUserAmount;
import com.wx.entity.WechatUserSession;

@Transactional
public interface UserService {

	WechatUser selectById(Integer id);
	
	int insert(WechatUser user);
	
	void updateById(WechatUser user);
	
	WechatUserSession findByOpenid(String openid);
	
	void insertUserSession(WechatUserSession session);
	
	Integer selectUidByToken(String token);
	
	void updateToken(Integer uid, String token);
	
	void updateLogin(Integer id, String dateLogin, String ipLogin);
	
	WechatUserAmount selectAmountByUid(Integer uid);
	
	void insertUserAmount(WechatUserAmount amount);
	
}
